package com.myway.components.ehic.support;

import java.util.Date;
import java.util.UUID;

import com.myway.components.ehic.model.YHConfig;
import com.myway.core.spring.SpringBeanUtil;


/**
 * 类名称：MobileContext <br/>
 * 类描述：设备之间的基础信息 <br/>
 * 创建时间：2016年3月2日 下午7:31:43 <br/>
 * @author 张涛
 * @version V1.0
 */
public class MobileContext {

	private String Version;
	
	private String DeviceId;
	
	private String Source;
	
	private String Channel;
	
	private String Extend;
	
	private String SequenceId;
	
	private Date TimeStamp;

	public MobileContext() {
		YHConfig yhConfig = (YHConfig) SpringBeanUtil.lookup("YHConfig");
		this.Version = yhConfig.getVersion();
		this.DeviceId = yhConfig.getDeviceId();
		this.Source = yhConfig.getSource();
		this.Channel = yhConfig.getChannel();
		this.Extend = yhConfig.getExtend();
		this.SequenceId = UUID.randomUUID().toString();
		this.TimeStamp = new Date();
	}

	public String getVersion() {
		return Version;
	}

	public void setVersion(String version) {
		Version = version;
	}

	public String getDeviceId() {
		return DeviceId;
	}

	public void setDeviceId(String deviceId) {
		DeviceId = deviceId;
	}

	public String getSource() {
		return Source;
	}

	public void setSource(String source) {
		Source = source;
	}

	public String getChannel() {
		return Channel;
	}

	public void setChannel(String channel) {
		Channel = channel;
	}

	public String getExtend() {
		return Extend;
	}

	public void setExtend(String extend) {
		Extend = extend;
	}

	public String getSequenceId() {
		return SequenceId;
	}

	public void setSequenceId(String sequenceId) {
		SequenceId = sequenceId;
	}

	public Date getTimeStamp() {
		return TimeStamp;
	}

	public void setTimeStamp(Date timeStamp) {
		TimeStamp = timeStamp;
	}


	
}
